//
//  Test45.cpp
//  CPPTest
//
//  Created by you5 Yi on 2021/9/29.
//

#include "Test45.hpp"
#include <iostream>
using namespace std;

void test45()
{
    char *a[5] = {"new","class","double","main","public"};
    char *p1,*p2;
    p1=p2=a[0];
    for (int i=0; i<5; i++) {
        if (strcmp(a[i], p1)<0) {
            p1=a[i];
        }
        if (strcmp(a[i], p2)<0) {
            p2=a[i];
        }
        cout<<p1<<','<<p2<<endl;
    }
}
